
#动态库的创建
libmystdio.so:mystring.o myprint.o
	g++ -o $@ $^ -shared
%.o:%.cc
	g++ -fPIC -c  $< 

.PHONY:clean
clean:
	rm -r -f *.o *.a *.so std
	
.PHONY:output
output:
	mkdir -p std/include
	mkdir -p std/lib 
	cp *.so std/lib 
	cp *.h std/include
	tar czf std.tgz std 










#静态库的创建
#libmystdio.a:mystring.o myprint.o
#	ar -rc $@ $^
#%.o:%.c
#	g++ -c $<
#
#.PHONY:clean
#clean:
#	rm -r -f *.a *.o std
#	
#.PHONY:output
#output:
#	mkdir -p std/include
#	mkdir -p std/lib 
#	cp *.a std/lib 
#	cp *.h std/include
#	tar czf std.tgz std 

